<template>
  <a-layout-header class="header">
    <a-button type="danger" @click="logonOut">注销</a-button>
  </a-layout-header>
</template>

<script>
export default {
  methods: {
    logonOut () {
      window.sessionStorage.clear('token')
      this.$router.push('/login')
    },
  },
}
</script>

<style scoped>
.header {
  display: flex;
  justify-content: flex-end;
  align-items: center;

  background-color: #3c40c6;
  background-image: url(https://flatuicolors.com/static/img/stars-opacity.0979c1.svg);
}
</style>
